package com.starview.star.compiler.format;

import com.starview.star.compiler.ast.IAttribute;

@SuppressWarnings("serial")
public abstract class BaseAttribute<T> implements IAttribute
{
  private final int specificity;
  private final boolean inheritable;

  public BaseAttribute(boolean inheritable, int specificity)
  {
    this.specificity = specificity;
    this.inheritable = inheritable;
  }

  public int getSpecificity()
  {
    return specificity;
  }

  @Override
  public boolean isIheritable()
  {
    return inheritable;
  }

  public abstract T apply(T original);
}
